home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 25 / CU Amiga Magazine's Super CD-ROM 25 (1998)(EMAP Images)(GB)(Track 1 of 2)[!][issue 1998-08].iso / CUCD / Programming / QuakeTools / src / libqtools / graphics.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-06-11  |  1.2 KB  |  50 lines

  1. #ifndef    GRAPHICS_H
  2. #define    GRAPHICS_H
  3. #include "script.h"
  4.  
  5. /*
  6.  * ============================================================================
  7.  * structures
  8.  * ============================================================================
  9.  */
  10.  
  11. struct palpic {
  12.   char *name;
  13.   short int width, height;
  14.   struct rgb *palette;
  15.   unsigned char rawdata[0];
  16. } __packed;
  17.  
  18. struct rawpic {
  19.   char *name;
  20.   short int width, height;
  21.   struct rgb rawdata[0];
  22. } __packed;
  23.  
  24. struct lump {
  25.   int width, height;
  26.   unsigned char rawdata[0];
  27. } __packed;
  28.  
  29. /*
  30.  * ============================================================================
  31.  * globals
  32.  * ============================================================================
  33.  */
  34.  
  35. extern bool dither;
  36. extern short int dithervalue;
  37. extern bool smoothing;
  38. extern short int smoothingvalue;
  39.  
  40. /*
  41.  * ============================================================================
  42.  * prototypes
  43.  * ============================================================================
  44.  */
  45.  
  46. bool RemapPalettes(unsigned char *dataBody, int dataSize, struct rgb *oldPalette, struct rgb *newPalette);
  47. struct palpic *GetImage(FILE *file, char *picName, short int alignX, short int alignY);
  48. bool PutImage(FILE *file, struct palpic *Picture, filetype picType);
  49. #endif
  50.